﻿<%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl" %>
<%@ Import Namespace="CNTVNow.Web.Helpers.ExtensionMethods" %>
<%@ Import Namespace="CNTVNow.Web.Models" %>
<%@ Import Namespace="CNTVNow.Web.Helpers.Common" %>
<%@ Import Namespace="System.Collections.Generic" %>
    <div class="box01">
        <ul class="news03">
        <%if (ViewData["NewsLeft"] != null)
        {
            var lstNews = (List<New>)ViewData["NewsLeft"];
            foreach (var news in lstNews)
            {
            %>
            <li>
                <div class="divblock">
                    <div class="divblock_main">
                        <a href="Detail.cntv?n=<%=news.NewsID%>"><img src="<%=ResolveUrl(news.AvatarImage)%>" alt="" height="69" width="99" class="right" /></a>
                        <div class="description">
                            <h3 class="style02"><a href="Detail.cntv?n=<%=news.NewsID%>"><%=news.NewsTitle%></a></h3>
                        </div>
                    </div>
                </div>
            </li>
            <%
            }
        }
        %>
        </ul>
    </div>
    <div class="box02 aligncenter">
        <%--<h2 class="style02">The new iMac<br /><small>All quad-core power. Up to 3x faster graphics. High-speed Thunderbolt I/O.</small></h2>
        <p><a href="#"><img src="<%=Url.GetUrlContentHome("images/temp/ads/img4.jpg")%>" alt="" height="90" width="161" /></a></p>--%>
        <%if (ViewData["AdsLeft"] != null)
          {
              var lstNews = (List<AdvertisementItem>)ViewData["AdsLeft"];
              foreach (var ads in lstNews)
              {   
              %>
                    <p><a href="<%=ads.Link%>"><img src="<%=ResolveUrl(ads.FileLink1)%>" alt="" height="90" width="161" /></a></p>
              <%
              }
          } %>
    </div>